package com.ithailong.mvn1.servlet;

/**
 * author:hlc
 * date:2023/10/19
 */
import com.wf.captcha.GifCaptcha;
import com.wf.captcha.utils.CaptchaUtil;
import javax.servlet.ServletException;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;

/**
 * 验证码
 * @author 17930
 */
@WebServlet("/captcha")
public class Captcha extends HttpServlet {
   @Override
   protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
      GifCaptcha gifCaptcha = new GifCaptcha(130, 20, 4);
      CaptchaUtil.out(request,response);
   }
}
